class People:
    def hello(self):
        print('hello people')

class Men(People):
    def hello(self):
        print('hello man')

class Women(People):
    def hello(self):
        print('hello woman')

class Test:
    def hello(self, arg):
        arg.hello()

p = People()
men = Men()
women = Women()
test = Test()
test.hello(p)
test.hello(men)
test.hello(women)